// components/wrapList/wrapList.js
Component({
  /**
   * 组件的属性列表
   */
  properties: {
    articleList:{
      type:Array,
      value:[{
        id:1,
        name:"官方",
        img:"../../static/tab_icon/discovery-active.png",
        time:"2023/3/22",
        title:"凤求凰",
        content:"凤兮凤兮归故乡，遨游四海求其凰",
        starCount:619,
        commentCount:15,
        tag:'原创'
      }]
    }
  },

  /**
   * 组件的初始数据
   */
  data: {

  },

  /**
   * 组件的方法列表
   */
  methods: {
    handleTapItem(e){
      const id = e.detail.id
      const star = e.detail.star
      if(id){
        wx.navigateTo({
          url: `/subpackages/articleDetail/articleDetail?id=${id}&star=${star}`,
        })
      }
    },
    handleTapItemPoetry(e){
      const id = e.detail.id
      if(id){
        wx.navigateTo({
          url: `/subpackages/poetryDetail/poetryDetail?poetry_id=${id}`,
        })
      }
    },
  }
})
